extends Control
@export var main_map: PackedScene
signal return_button_pressed

@onready var zs_button: Button = $Panel/HBoxContainer/MarginContainer/Button
@onready var fs_button = $Panel/HBoxContainer/MarginContainer2/Button
@onready var fz_button = $Panel/HBoxContainer/MarginContainer3/Button
@onready var text_edit = $Panel/TextEdit

func _ready():
	zs_button.set_toggle_mode(true)
	text_edit.set_text("勇士,忠实的盾")

func _on_return_button_pressed():
	return_button_pressed.emit()


func _on_start_button_pressed():
	print("选取职业:" + str(Globals.player_type))
	get_tree().change_scene_to_packed(main_map)


func _on_button_toggled(toggled_on):
	Globals.player_type = 0
